<h1><%= t(:departments) %></h1>

<ul>
  <% @departments.each do |d| %>
    
    <li>
      <span class="department-name"><%= d.name %></span>
      <ul class="department-actions">
        <li><%= link_to t(:edit), edit_admin_department_path(d.id) %></li>
        <li><%= link_to t(:remove), admin_department_path(d.id), :method => 'delete', :confirm => t(:confirmation_message) %></li>
      </ul>
    </li>
  
  <% end %>
</ul>

<p id="new-department"><%= link_to t(:new_department), new_admin_department_path %></p>
<p class="back"><%= link_to t(:back), '/admin' %></p>
